<template>
	<view class="container">
		<view class="header">
			<view class="title">兑换中心</view>
			<view class="subtitle">用环保积分兑换好礼</view>
		</view>
		
		<view class="content">
			<view class="points-card">
				<view class="points-title">我的积分</view>
				<view class="points-value">2,800</view>
				<view class="points-desc">继续环保行动，获得更多积分</view>
			</view>
			
			<view class="section">
				<view class="section-title">热门兑换</view>
				<view class="exchange-list">
					<view class="exchange-item" v-for="(item, index) in exchangeItems" :key="index">
						<view class="item-icon">{{ item.icon }}</view>
						<view class="item-info">
							<view class="item-title">{{ item.title }}</view>
							<view class="item-desc">{{ item.description }}</view>
						</view>
						<view class="item-points">{{ item.points }}积分</view>
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
export default {
	data() {
		return {
			exchangeItems: [
				{
					title: '环保购物袋',
					description: '可重复使用的环保购物袋',
					points: 500,
					icon: '🛍️'
				},
				{
					title: '不锈钢水杯',
					description: '减少一次性水杯使用',
					points: 800,
					icon: '🥤'
				},
				{
					title: '有机肥料',
					description: '家庭种植专用有机肥料',
					points: 1200,
					icon: '🌱'
				},
				{
					title: '环保书籍',
					description: '环保知识科普书籍',
					points: 1500,
					icon: '📖'
				}
			]
		}
	}
}
</script>

<style lang="scss" scoped>
.container {
	min-height: 100vh;
	background-color: #f5f5f5;
}

.header {
	background: linear-gradient(135deg, #4CAF50, #8BC34A);
	padding: 60rpx 40rpx 40rpx;
	color: white;
	
	.title {
		font-size: 48rpx;
		font-weight: bold;
		margin-bottom: 10rpx;
	}
	
	.subtitle {
		font-size: 28rpx;
		opacity: 0.9;
	}
}

.content {
	padding: 30rpx 40rpx;
}

.points-card {
	background: linear-gradient(90deg, #FFD700, #FFA500);
	border-radius: 20rpx;
	padding: 40rpx;
	margin-bottom: 40rpx;
	text-align: center;
	color: white;
	box-shadow: 0 8rpx 24rpx rgba(255, 215, 0, 0.3);
	
	.points-title {
		font-size: 28rpx;
		margin-bottom: 10rpx;
		opacity: 0.9;
	}
	
	.points-value {
		font-size: 72rpx;
		font-weight: bold;
		margin-bottom: 10rpx;
	}
	
	.points-desc {
		font-size: 24rpx;
		opacity: 0.8;
	}
}

.section {
	.section-title {
		font-size: 36rpx;
		font-weight: bold;
		color: #333;
		margin-bottom: 30rpx;
	}
	
	.exchange-list {
		.exchange-item {
			background: white;
			border-radius: 16rpx;
			padding: 30rpx;
			margin-bottom: 20rpx;
			display: flex;
			align-items: center;
			box-shadow: 0 4rpx 12rpx rgba(0, 0, 0, 0.1);
			
			.item-icon {
				font-size: 48rpx;
				margin-right: 20rpx;
			}
			
			.item-info {
				flex: 1;
				
				.item-title {
					font-size: 30rpx;
					font-weight: bold;
					color: #333;
					margin-bottom: 8rpx;
				}
				
				.item-desc {
					font-size: 24rpx;
					color: #666;
				}
			}
			
			.item-points {
				font-size: 28rpx;
				font-weight: bold;
				color: #FF6B35;
			}
		}
	}
}
</style> 